//
//  LoginViewController.swift
//  Wallpaper
//
//  Created by    on 2023/12/19.
//

import UIKit

class LoginViewController: UIViewController {
    @IBOutlet weak var loginBtn : UIButton?
    @IBOutlet weak var registerBtn : UIButton?
    @IBOutlet weak var  closeBtn : UIButton?

    @IBOutlet weak var  phoneNumber:UITextField?
    @IBOutlet weak var  verificationCode:UITextField?
    @IBOutlet weak var  sendButton:UIButton?
    @IBOutlet weak var  bg:UIView?

    
    override func viewDidLoad() {
        super.viewDidLoad()
    }
    
    ///  登录
    @IBAction func login() {
        registerBtn?.isHidden = true
        closeBtn?.isHidden = false
        bg?.isHidden = false
        
        NotificationCenter.default.post(name: Notification.Name(loginSuccess), object: nil)
    }
    
    @IBAction func cancel() {
        closeBtn?.isHidden = true
        loginBtn?.isHidden = false
        registerBtn?.isHidden = false
        bg?.isHidden = true
    }
    
    /// 注册
    @IBAction func register() {
        loginBtn?.isHidden = true
        closeBtn?.isHidden = false
        bg?.isHidden = false
    }
}
